package com.ag.improvedjava.utils.predicates;

import com.ag.improvedjava.utils.Predicate;

public class PredicatesForNumbers {	
	
	public static Predicate<Number> POSITIVE = new Predicate<Number>(){
		public boolean evaluate(Number number) {
			return number.doubleValue() >= 0;
		}
	};
	
	public static Predicate<Number> STRICTLY_POSITIVE = new Predicate<Number>(){
		public boolean evaluate(Number number) {
			return number.doubleValue() > 0;
		}
	};
	
	public static Predicate<Number> NEGATIVE = new Predicate<Number>(){
		public boolean evaluate(Number number) {
			return number.doubleValue() <= 0;
		}
	};
	
	public static Predicate<Number> STRICTLY_NEGATIVE = new Predicate<Number>(){
		public boolean evaluate(Number number) {
			return number.doubleValue() < 0;
		}
	};
	
	public static Predicate<Number> ZERO = new Predicate<Number>(){
		public boolean evaluate(Number number) {
			return number.doubleValue() == 0;
		}
	};
	
}
